using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._LocationReferencingTools._Configuration._LRSNetwork
{
    /// <summary>
    /// <para>Modify LRS Network</para>
    /// <para>Modifies an LRS Network in a Location Referencing linear referencing system (LRS).</para>
    /// <para>修改位置参考线性参考系统 （LRS） 中的 LRS 网络。</para>
    /// </summary>    
    [DisplayName("Modify LRS Network")]
    public class ModifyLRSNetwork : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public ModifyLRSNetwork()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_in_feature_class">
        /// <para>LRS Network Feature Class</para>
        /// <para>The input LRS Network feature class to be modified.</para>
        /// <para>要修改的输入 LRS 网络要素类。</para>
        /// </param>
        public ModifyLRSNetwork(object _in_feature_class)
        {
            this._in_feature_class = _in_feature_class;
        }
        public override string ToolboxName => "Location Referencing Tools";

        public override string ToolName => "Modify LRS Network";

        public override string CallName => "locref.ModifyLRSNetwork";

        public override List<string> AcceptEnvironments => ["workspace"];

        public override object[] ParameterInfo => [_in_feature_class, _route_id_field, _route_name_field, _from_date_field, _to_date_field, _derive_from_line_network.GetGPValue(), _line_network_name, _include_fields_to_support_lines.GetGPValue(), _line_id_field, _line_name_field, _line_order_field, _out_feature_class, _route_id_configuration.GetGPValue(), _individual_route_id_fields];

        /// <summary>
        /// <para>LRS Network Feature Class</para>
        /// <para>The input LRS Network feature class to be modified.</para>
        /// <para>要修改的输入 LRS 网络要素类。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("LRS Network Feature Class")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_feature_class { get; set; }


        /// <summary>
        /// <para>Route ID Field</para>
        /// <para>The field in the input feature class that will be mapped as the LRS Network route ID. The field type must match the RouteId field type of the Centerline_Sequence table and must either be a string or GUID field type.</para>
        /// <para>输入要素类中将映射为 LRS 网络路径 ID 的字段。字段类型必须与 Centerline_Sequence 表的 RouteId 字段类型匹配，并且必须是字符串或 GUID 字段类型。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Route ID Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _route_id_field { get; set; } = null;


        /// <summary>
        /// <para>Route Name Field</para>
        /// <para>A string field in the input feature class that will be mapped as the LRS Network route name.</para>
        /// <para>输入要素类中的字符串字段，将映射为 LRS 网络路径名称。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Route Name Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _route_name_field { get; set; } = null;


        /// <summary>
        /// <para>From Date Field</para>
        /// <para>A date field in the input feature class that will be mapped as the LRS Network from date.</para>
        /// <para>输入要素类中的日期字段，该字段将从日期开始映射为 LRS 网络。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("From Date Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _from_date_field { get; set; } = null;


        /// <summary>
        /// <para>To Date Field</para>
        /// <para>A date field in the input feature class that will be mapped as the LRS Network to date.</para>
        /// <para>输入要素类中的日期字段，该字段将映射为迄今为止的 LRS 网络。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("To Date Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _to_date_field { get; set; } = null;


        /// <summary>
        /// <para>Derive From Line Network</para>
        /// <para><xdoc>
        ///   <para>Determines if the current LRS network will be configured as an LRS Derived Network.</para>
        ///   <bulletList>
        ///     <bullet_item>As is—The current LRS Network derived property will not be changed. This is the default.</bullet_item><para/>
        ///     <bullet_item>Derive—The input LRS Derived Network will be modified to become an LRS Derived Network. The line network name parameter must also be provided to specify which LRS Network to derive from.</bullet_item><para/>
        ///     <bullet_item>Do not derive—The input LRS Derived Network will be modified to no longer be an LRS Derived Network.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>确定是否将当前 LRS 网络配置为 LRS 派生网络。</para>
        ///   <bulletList>
        ///     <bullet_item>按原样 - 不会更改当前 LRS 网络派生属性。这是默认设置。</bullet_item><para/>
        ///     <bullet_item>派生—输入 LRS 派生网络将被修改为“LRS 派生网络”。还必须提供线路网络名称参数，以指定要从哪个 LRS 网络派生。</bullet_item><para/>
        ///     <bullet_item>不派生 - 输入 LRS 派生网络将被修改为不再是 LRS 派生网络。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Derive From Line Network")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _derive_from_line_network_value _derive_from_line_network { get; set; } = _derive_from_line_network_value._AS_IS;

        public enum _derive_from_line_network_value
        {
            /// <summary>
            /// <para>As is</para>
            /// <para>As is—The current LRS Network derived property will not be changed. This is the default.</para>
            /// <para>按原样 - 不会更改当前 LRS 网络派生属性。这是默认设置。</para>
            /// </summary>
            [Description("As is")]
            [GPEnumValue("AS_IS")]
            _AS_IS,

            /// <summary>
            /// <para>Do not derive</para>
            /// <para>Do not derive—The input LRS Derived Network will be modified to no longer be an LRS Derived Network.</para>
            /// <para>不派生 - 输入 LRS 派生网络将被修改为不再是 LRS 派生网络。</para>
            /// </summary>
            [Description("Do not derive")]
            [GPEnumValue("DO_NOT_DERIVE")]
            _DO_NOT_DERIVE,

            /// <summary>
            /// <para>Derive</para>
            /// <para>Derive—The input LRS Derived Network will be modified to become an LRS Derived Network. The line network name parameter must also be provided to specify which LRS Network to derive from.</para>
            /// <para>派生—输入 LRS 派生网络将被修改为“LRS 派生网络”。还必须提供线路网络名称参数，以指定要从哪个 LRS 网络派生。</para>
            /// </summary>
            [Description("Derive")]
            [GPEnumValue("DERIVE")]
            _DERIVE,

        }

        /// <summary>
        /// <para>Line Network Name</para>
        /// <para>The name of the LRS Line Network to which the input LRS Derived Network will be registered. The input LRS Line Network must reside in the same geodatabase workspace and LRS as the LRS network feature class. This parameter is only used if the Derive From Line Network parameter is set to Derive.</para>
        /// <para>输入 LRS 派生网络将注册到的 LRS 线路网络的名称。输入 LRS 线网络必须与 LRS 网络要素类位于同一地理数据库工作空间和 LRS 中。仅当“从线网络派生”参数设置为“派生”时，才使用此参数。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Line Network Name")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _line_network_name { get; set; } = null;


        /// <summary>
        /// <para>Include Fields to Support Lines</para>
        /// <para><xdoc>
        ///   <para>Determines if the current LRS network will be configured to support lines.</para>
        ///   <bulletList>
        ///     <bullet_item>As is—The current LRS Network line support property will not be changed. This is the default.</bullet_item><para/>
        ///     <bullet_item>Include—The input LRS Network will be modified to add support for lines. The line id field, line name field, and line order field parameters must also be provided, and valid fields to map to these parameters must exist in the LRS network feature class.</bullet_item><para/>
        ///     <bullet_item>Do not include—The input LRS Network will be modified to remove support for lines.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>确定是否将当前 LRS 网络配置为支持线路。</para>
        ///   <bulletList>
        ///     <bullet_item>按原样 - 不会更改当前 LRS 网络线路支持属性。这是默认设置。</bullet_item><para/>
        ///     <bullet_item>包括—将修改输入 LRS 网络以添加对线的支持。还必须提供线 ID 字段、线名称字段和线顺序字段参数，并且要映射到这些参数的有效字段必须存在于 LRS 网络要素类中。</bullet_item><para/>
        ///     <bullet_item>不包括 - 将修改输入 LRS 网络以移除对线路的支持。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Include Fields to Support Lines")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _include_fields_to_support_lines_value _include_fields_to_support_lines { get; set; } = _include_fields_to_support_lines_value._AS_IS;

        public enum _include_fields_to_support_lines_value
        {
            /// <summary>
            /// <para>As is</para>
            /// <para>As is—The current LRS Network line support property will not be changed. This is the default.</para>
            /// <para>按原样 - 不会更改当前 LRS 网络线路支持属性。这是默认设置。</para>
            /// </summary>
            [Description("As is")]
            [GPEnumValue("AS_IS")]
            _AS_IS,

            /// <summary>
            /// <para>Do not include</para>
            /// <para>Do not include—The input LRS Network will be modified to remove support for lines.</para>
            /// <para>不包括 - 将修改输入 LRS 网络以移除对线路的支持。</para>
            /// </summary>
            [Description("Do not include")]
            [GPEnumValue("DO_NOT_INCLUDE")]
            _DO_NOT_INCLUDE,

            /// <summary>
            /// <para>Include</para>
            /// <para>Include—The input LRS Network will be modified to add support for lines. The line id field, line name field, and line order field parameters must also be provided, and valid fields to map to these parameters must exist in the LRS network feature class.</para>
            /// <para>包括—将修改输入 LRS 网络以添加对线的支持。还必须提供线 ID 字段、线名称字段和线顺序字段参数，并且要映射到这些参数的有效字段必须存在于 LRS 网络要素类中。</para>
            /// </summary>
            [Description("Include")]
            [GPEnumValue("INCLUDE")]
            _INCLUDE,

        }

        /// <summary>
        /// <para>Line ID Field</para>
        /// <para>The field in the input feature class that will be mapped as the LRS Network line ID. This parameter is only used if the Include Fields to Support Lines parameter is set to Include. The field type must match the RouteId field type of the Centerline_Sequence table and must either be a string of exactly 38 characters or a GUID field type.</para>
        /// <para>输入要素类中将映射为 LRS 网络线路 ID 的字段。仅当“包括支持行的字段”参数设置为“包含”时，才使用此参数。字段类型必须与 Centerline_Sequence 表的 RouteId 字段类型匹配，并且必须是正好包含 38 个字符的字符串或 GUID 字段类型。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Line ID Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _line_id_field { get; set; } = null;


        /// <summary>
        /// <para>Line Name Field</para>
        /// <para>A string field in the input feature class that will be mapped as the LRS Network line name. This parameter is only used if the Include Fields to Support Lines parameter is set to Include.</para>
        /// <para>输入要素类中的字符串字段，将映射为 LRS 网络线名称。仅当“包括支持行的字段”参数设置为“包含”时，才使用此参数。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Line Name Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _line_name_field { get; set; } = null;


        /// <summary>
        /// <para>Line Order Field</para>
        /// <para>The field in the input feature class that will be mapped as the LRS Network line order. This parameter is only used if the Include Fields to Support Lines parameter is set to Include. This must be a long integer field type.</para>
        /// <para>输入要素类中将映射为 LRS 网络线顺序的字段。仅当“包括支持行的字段”参数设置为“包含”时，才使用此参数。这必须是长整数字段类型。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Line Order Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _line_order_field { get; set; } = null;


        /// <summary>
        /// <para>Output Network Feature Class</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Network Feature Class")]
        [Description("")]
        [Option(OptionTypeEnum.derived)]
        public object _out_feature_class { get; set; }


        /// <summary>
        /// <para>Route ID Field Configuration</para>
        /// <para><xdoc>
        ///   <para>Determines the route ID configuration for an LRS Network.</para>
        ///   <bulletList>
        ///     <bullet_item>As is—The current LRS Network route ID configuration will not be changed. This is the default.</bullet_item><para/>
        ///     <bullet_item>Autogenerated Route ID—The route ID field will be an autogenerated GUID, and the route name can be configured as an LRS field.</bullet_item><para/>
        ///     <bullet_item>Single-Field Route ID—Supported only for nonline networks.</bullet_item><para/>
        ///     <bullet_item>Multi-Field Route ID—Supported only for nonline networks. More than one field is needed to form the concatenated route ID.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>确定 LRS 网络的路由 ID 配置。</para>
        ///   <bulletList>
        ///     <bullet_item>按原样 - 当前 LRS 网络路由 ID 配置不会更改。这是默认设置。</bullet_item><para/>
        ///     <bullet_item>自动生成的路由 ID - 路由 ID 字段将是自动生成的 GUID，并且路由名称可以配置为 LRS 字段。</bullet_item><para/>
        ///     <bullet_item>单字段路由 ID — 仅支持 nonline 网络。</bullet_item><para/>
        ///     <bullet_item>多字段路由 ID — 仅支持 nonline 网络。需要多个字段来形成串联的路由 ID。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Route ID Field Configuration")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _route_id_configuration_value _route_id_configuration { get; set; } = _route_id_configuration_value._AS_IS;

        public enum _route_id_configuration_value
        {
            /// <summary>
            /// <para>As is</para>
            /// <para>As is—The current LRS Network route ID configuration will not be changed. This is the default.</para>
            /// <para>按原样 - 当前 LRS 网络路由 ID 配置不会更改。这是默认设置。</para>
            /// </summary>
            [Description("As is")]
            [GPEnumValue("AS_IS")]
            _AS_IS,

            /// <summary>
            /// <para>Autogenerated Route ID</para>
            /// <para>Autogenerated Route ID—The route ID field will be an autogenerated GUID, and the route name can be configured as an LRS field.</para>
            /// <para>自动生成的路由 ID - 路由 ID 字段将是自动生成的 GUID，并且路由名称可以配置为 LRS 字段。</para>
            /// </summary>
            [Description("Autogenerated Route ID")]
            [GPEnumValue("AUTOGENERATED_ROUTE_ID")]
            _AUTOGENERATED_ROUTE_ID,

            /// <summary>
            /// <para>Single-Field Route ID</para>
            /// <para>Single-Field Route ID—Supported only for nonline networks.</para>
            /// <para>单字段路由 ID — 仅支持 nonline 网络。</para>
            /// </summary>
            [Description("Single-Field Route ID")]
            [GPEnumValue("SINGLE_FIELD_ROUTE_ID")]
            _SINGLE_FIELD_ROUTE_ID,

            /// <summary>
            /// <para>Multi-Field Route ID</para>
            /// <para>Multi-Field Route ID—Supported only for nonline networks. More than one field is needed to form the concatenated route ID.</para>
            /// <para>多字段路由 ID — 仅支持 nonline 网络。需要多个字段来形成串联的路由 ID。</para>
            /// </summary>
            [Description("Multi-Field Route ID")]
            [GPEnumValue("MULTI_FIELD_ROUTE_ID")]
            _MULTI_FIELD_ROUTE_ID,

        }

        /// <summary>
        /// <para>Field(s)</para>
        /// <para>The individual fields in the LRS Network Feature Class that will be used to form the route ID. This parameter is only used if the Route ID Field Configuration parameter's Multi-Field Route ID option is set. The fields must be either string or number integer field types.</para>
        /// <para>LRS 网络要素类中将用于构成路径 ID 的各个字段。仅当设置了路由 ID 字段配置参数的多字段路由 ID 选项时，才使用此参数。字段必须是字符串或数字整数字段类型。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Field(s)")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public List<object> _individual_route_id_fields { get; set; } = null;


        public ModifyLRSNetwork SetEnv(object workspace = null)
        {
            base.SetEnv(workspace: workspace);
            return this;
        }

    }

}